package com.king.zxing.app.domain;


import android.util.Pair;

import com.king.zxing.app.R;

import java.util.ArrayList;
import java.util.List;

/**
 * 仅用于显示于商场列表
 */
public class Goods {
    public final long id;

    public final String name;
    public final String price;
    public final long imageID;
    public final List<Pair<String, String>> tags;

    public Goods(long id, String name, String price, long imageID, List<Pair<String, String>> tags) {
        this.id = id;
        this.name = name;
        this.price = price;
        this.imageID = imageID;
        this.tags = tags;
    }

    /**
     * 临时测试使用
     */
    static public int askImageResource(int id) {
        switch (id) {
            case 1:
                return R.drawable.goods_item_1;
            case 2:
                return R.drawable.goods_item_2;
            case 3:
                return R.drawable.goods_item_3;
            default:
                return R.drawable.goods_image;
        }
    }

}
